package com.lc.pda.exception.base;

import lombok.Data;

/**
 * 基础异常
 * @author NASH.LEE
 */
@Data
public class BaseException extends RuntimeException {
    private static final long serialVersionUID = 1L;
    /**
     * 状态码
     */
    private int code = 500;
    /**
     * 返回内容
     */
    private String msg;


    public BaseException(String msg) {
        super(msg);
        this.msg = msg;
    }

    public BaseException(String msg, Throwable e) {
        super(msg, e);
        this.msg = msg;
    }

    public BaseException(int code, String msg) {
        super(msg);
        this.msg = msg;
        this.code = code;
    }

    public BaseException(int code, String msg, Throwable e) {
        super(msg, e);
        this.msg = msg;
        this.code = code;
    }
}
